import { post } from '@/core/utils/http';
import type { Response } from '@/core/models';

/**  获取代理商进度状态 */
export const queryAgentInfo = (data ?: any) : Promise<Response<any>> => {
	return post('Api/Agent/Info', {
		data,
	}, true);
}

/**  申请代理商 */
export const queryApplyAgent = (data ?: any) : Promise<Response<any>> => {
	return post('Api/Agent/ApplyAgent', {
		data,
	}, true);
}

/**  代理团队统计 */
export const queryAgentTeamSum = (data ?: any) : Promise<Response<any>> => {
	return post('Api/Agent/GetTeamSum', {
		data,
	}, true);
}

/**  代理订单统计 */
export const queryAgentOrderSum = (data ?: any) : Promise<Response<any>> => {
	return post('Api/Agent/GetOrderSum', {
		data,
	}, true);
}

/**  我的代理订单 */
export const queryAgentMyOrder = (data : any) : Promise<Response<any>> => {
	return post('Api/Agent/MyOrder', {
		data,
	}, true);
}

/**  获取代理池商品数据 */
export const queryAgentGoodsPageList = (data : any) : Promise<Response<any>> => {
	return post('Api/Agent/GetGoodsPageList', {
		data,
	}, true);
}

/**  获取店铺信息 */
export const queryAgentStoreInfot = (data : any) : Promise<Response<any>> => {
	return post('Api/Agent/GetStoreInfo', {
		data,
	}, true);
}

/**  店铺设置 */
export const queryAgentSetStore = (data : any) : Promise<Response<any>> => {
	return post('Api/Agent/SetStore', {
		data,
	}, true);
}

/**  获取代理商排行 */
export const queryAgentRanking = (data : any) : Promise<Response<any>> => {
	return post('Api/Agent/GetAgentRanking', {
		data,
	}, true);
}

/**  搜索获取门店订单列表 */
export const queryOrderPageByMerchantSearch = (data : any) : Promise<Response<any>> => {
	return post('Api/Store/GetOrderPageByMerchantSearch', {
		data,
	}, true);
}